import request from '@/utils/request'


// 查询供应商列表
export function selectAll(query) {
  return request({
    url: '/drug/supplier/selectAll',
    method: 'get',
    params: query
  })
}


// 新增供应商
export function addSupplier(data) {
  return request({
    url: '/drug/supplier/addSupplier',
    method: 'post',
    data: data
  })
}


// 根据id查询单个供应商
export function selectOne(dsid) {
  return request({
    url: '/drug/supplier/selectOne/' + dsid,
    method: 'get'
  })
}


// 修改供应商信息
export function updateSupplier(data) {
  return request({
    url: '/drug/supplier/updateSupplier',
    method: 'put',
    data: data
  })
}


// 删除供应商
export function deleteSupplier(dsids) {
  return request({
    url: '/drug/supplier/deleteSupplier/' + dsids,
    method: 'delete'
  })
}
